1. Field of the Invention
The present invention relates to a debugging device and a debugging method, and particularly to a debugging device and a debugging method which debug a program.
2. Description of the Related Art
Conventionally, in creating a program, debugging is performed using a debugging device in order to check whether or not the program operates correctly. The debugging device receives as input an object program generated by a compiling device, and displays a corresponding source code or assembly code on a graphical user interface (hereinafter referred to as GUI).
The debugging device has functions of performing break point setting, step execution, and the like. For example, a debugging operator performs step execution using the GUI, the debugging device executes one line of the source code or one instruction of the assembly code. Then, if there is a problematic code which leads to an error in a result of execution of the one instruction of the source code or assembly code, the debugging device highlights a problematic portion or displays an auxiliary code, message, or the like which represents details of the error. Accordingly, the debugging operator can easily find the problematic code.
Many debugging devices as described above have been proposed. For example, Japanese Patent Application No. 3107151 has proposed a debugging device which displays an auxiliary code, message, or the like in a source code or assembly code while a debugging operator performs debugging.
In this proposal, in a case where a debugging operator performs step execution at source level, if the execution sequence of the source code is changed due to optimization of a compiler, a message for alerting the debugging operator is displayed.
However, while conventional debugging devices can display an auxiliary message in the problematic code as described above, the conventional debugging devices cannot distinguish between information of a code that does not need to be debugged which is generated by optimization of the compiler during debugging and information of a code that needs to be debugged.
In addition, the conventional debugging devices can neither add a massage to a start position and an end position of the distinguished code that does not need to be debugged, nor hide the code itself.